package com.example.basicquestions.questions.对称字符串;

import java.util.Scanner;

/**
 * @author liw
 * @date 2023-03-11
 */
public class Test {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int t = scanner.nextInt();
        for (int i =0;i < t;i++) {
            int r = scanner.nextInt();
            long c = scanner.nextLong();
            String res = recursionResult(r,c+1);
            System.out.println(res);
        }

    }

    public static String recursionResult(long n,long k){

        if(n == 1 && k == 1){
            return "red";
        }else if(n == 2 && k == 1){
            return "blue";
        }
        long l = (long) Math.pow(2,n-1);
        if(k > l/2){
            return recursionResult(n-1,k-(long)Math.pow(2,n-2));
        }else{
            return recursionResult(n-1, (long)Math.pow(2,n-2));
        }
    }
}
